package zoo.animals.mammal;

import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import zoo.food.Food;
import zoo.food.Meat;

/**
 * Created with IntelliJ IDEA.
 * User: platonovv
 * Date: 25.11.13
 * To change this template use File | Settings | File Templates.
 */
public class Dog extends Mammal {
    private static final Log log = LogFactory.getLog(Mammal.class);

    public Dog(String name, int age) {
        super(name, age);
    }

    @Override
    public void voice() {
        log.info("woof woof");
    }

    @Override
    public void feed(Food food) {
        if (food instanceof Meat)
            voice();
    }

}
